<?php
namespace app\common\model;
use think\model\concern\SoftDelete;

class Copy extends TyModel {

    use SoftDelete;
    protected $deleteTime = 'delete_time';
    protected $defaultSoftDelete = 0;

    //数据源类型
    public function getSourceNameAttr($value,$data){
        $status = [1 => '巡店',2 => '内部协同',3 => '推广工作',4 => '工作日志',5 => '活动开展',6 => '通知公告'];
        return $status[$data['source']];
    }
}